﻿using Colorful.Models;
using MongoDB.Bson.Serialization.Attributes;
using System;
using System.Collections.Generic;
using System.Text;

namespace Colorful.Apps.ERP.Models
{
    /// <summary>
    /// 产品表
    /// </summary>
    public class Product : BaseId
    {
        /// <summary>
        /// 产品编号
        /// </summary>
        public string Code { get; set; }
        /// <summary>
        /// 产品名称
        /// </summary>
        public string Name { get; set; }
        /// <summary>
        /// 产品类别
        /// </summary>
        public int SortId { get; set; }
        /// <summary>
        /// 品牌
        /// </summary>
        public string Brand { get; set; }
        /// <summary>
        /// 产地
        /// </summary>
        public string Place { get; set; }
        /// <summary>
        /// 宣传视频
        /// </summary>
        public string Video { get; set; }
        /// <summary>
        /// 产品缩略图
        /// </summary>
        public string Photo { get; set; }
        /// <summary>
        /// 产品图片
        /// </summary>
        public List<string> Images { get; set; }
        /// <summary>
        /// 产品介绍
        /// </summary>
        public string Intro { get; set; }
        /// <summary>
        /// 产品备注
        /// </summary>
        public string Remark { get; set; }
        /// <summary>
        /// 产品标签
        /// </summary>
        public List<string> Tags { get; set; }
        /// <summary>
        /// 产品标识（ProductFlags枚举）
        /// </summary>
        public List<int> Flags { get; set; }
        /// <summary>
        /// 参考价格
        /// </summary>
        public string Price { get; set; }
        /// <summary>
        /// 所属季节
        /// </summary>
        public List<int> Seasons { get; set; }
        /// <summary>
        /// 产品规格列表
        /// </summary>
        public List<ProductShow> List { get; set; }
        /// <summary>
        /// 关键词
        /// </summary>
        public string Keyword { get; set; }
        /// <summary>
        /// 排序
        /// </summary>
        public long ByOrder { get; set; }
    }
    /// <summary>
    /// 展示产品表
    /// </summary>
    public class ProductShow
    {
        /// <summary>
        /// 产品Id
        /// </summary>
        public string Id { get; set; }
        /// <summary>
        /// 产品规格
        /// </summary>
        public string Spec { get; set; }
        /// <summary>
        /// 产品价格
        /// </summary>
        public decimal Price { get; set; }
        /// <summary>
        /// 参考价格
        /// </summary>
        public decimal ReferencePrice { get; set; }
        /// <summary>
        /// 数量
        /// </summary>
        public int Amount { get; set; }
        /// <summary>
        /// 颜色
        /// </summary>
        public List<string> Colors { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        public string Remark { get; set; }
        /// <summary>
        /// 折扣
        /// </summary>
        public decimal Discount { get; set; }
    }
}
